package com.moneywelcome.loanservicefacade.forms;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

@ApiModel("用户贷款参数表")
@Data
public class LoanForm {
    @ApiModelProperty(value = "贷款产品id",required = true)
    @NotNull
    private Integer loanProductId;

    @ApiModelProperty(value = "还款期数",required = true)
    @NotNull
    private Integer loanStage;

    @ApiModelProperty(value = "贷款金额",required = true)
    @NotNull
    private Double money;

    @ApiModelProperty(value = "银行卡号",required = true)
    @NotNull
    @Pattern(message = "银行卡号格式不对",regexp = "^([1-9]{1})(\\d{14}|\\d{18})$")
    private String bankAccount;
}
